package com.example.service;

import org.springframework.stereotype.Component;
import org.springframework.transaction.annotation.Transactional;



@Component("personService")
@Transactional
class PersonServiceImpl implements PersonService {

    private final PersonRepository personRepository;


    public PersonServiceImpl(PersonRepository personRepository) {
        this.personRepository = personRepository;
    }

    @Override
    public Boolean existsByIDNum(String id_num){
        return this.personRepository.existsByIdNum(id_num);
    }

}